<?php
    $appearanceTime = new RedCross_Date();
    $appearanceTime->import($this->shift->appearance_time);
    
    $fromDate = new RedCross_Date();
    $fromDate->import($this->shift->from_date);
    
    $toDate = new RedCross_Date();
    $toDate->import($this->shift->to_date);
?>
<table class="shift_summary">
    <thead>
        <tr>
            <th colspan="2"><?php echo $this->escape($this->shift->name); ?></th>
        </tr>
    </thead>
    <tbody>
        <tr>
            <td>Oppmøtetidspunkt</td>
            <td>
            <?php
                if ($appearanceTime == $fromDate)
                {
                    echo "Direkte på arrangement";
                }
                else
                {
                    echo $appearanceTime->getDateTimeStr();
                }
            ?>
            </td>
        </tr>
        <tr>
            <td>Starttidspunkt</td>
            <td>
            <?php
                echo $fromDate->getDateTimeStr();
            ?>
            </td>
        </tr>
        <tr>
            <td>Sluttidspunkt</td>
            <td>
            <?php
                echo $toDate->getDateTimeStr();
            ?>
            </td>
        </tr>
        <tr>
            <td>Spesiell beskrivelse</td>
            <td><?php echo $this->escape($this->shift->special_description); ?></td>
        </tr>
        <tr>
            <td>Utstyrsliste</td>
            <td><?php echo $this->escape($this->shift->equipment_list); ?></td>
        </tr>
    </tbody>
</table>
